790c22bd01f4999548b10520c2e993680623deb3,features/src/main/java/org/apache/karaf/cellar/features/FeaturesSynchronizer.java,FeaturesSynchronizer,sync,#Group#,73
Before Change
}
if (policy.equalsIgnoreCase("cluster")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'cluster' for cluster group {}", group.getName());
LOGGER.debug("CELLAR FEATURE: updating node from the cluster (pull first)");
pull(group);
LOGGER.debug("CELLAR FEATURE: updating cluster from the local node (push after)");
push(group);
} else if (policy.equalsIgnoreCase("node")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'node' for cluster group {}", group.getName());
LOGGER.debug("CELLAR FEATURE: updating cluster from the local node (push first)");
push(group);
LOGGER.debug("CELLAR FEATURE: updating node from the cluster (pull after)");
pull(group);
} else if (policy.equalsIgnoreCase("clusterOnly")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'clusterOnly' for cluster group " + group.getName());
LOGGER.debug("CELLAR FEATURE: updating node from the cluster (pull only)");
pull(group);
} else if (policy.equalsIgnoreCase("nodeOnly")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'nodeOnly' for cluster group " + group.getName());
LOGGER.debug("CELLAR FEATURE: updating cluster from the local node (push only)");
After Change
}
if (policy.equalsIgnoreCase("cluster")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'cluster' for cluster group {}", group.getName());
if (clusterManager.listNodesByGroup(group).size() > 1) {
LOGGER.debug("CELLAR FEATURE: updating node from the cluster (pull first)");
pull(group);
} else {
LOGGER.debug("CELLAR FEATURE: node is the first one in the cluster group, no pull");
}
LOGGER.debug("CELLAR FEATURE: updating cluster from the local node (push after)");
push(group);
} else if (policy.equalsIgnoreCase("node")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'node' for cluster group {}", group.getName());
LOGGER.debug("CELLAR FEATURE: updating cluster from the local node (push first)");
push(group);
LOGGER.debug("CELLAR FEATURE: updating node from the cluster (pull after)");
pull(group);
} else if (policy.equalsIgnoreCase("clusterOnly")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'clusterOnly' for cluster group " + group.getName());
if (clusterManager.listNodesByGroup(group).size() > 1) {
LOGGER.debug("CELLAR FEATURE: updating node from the cluster (pull only)");
pull(group);
} else {
LOGGER.debug("CELLAR FEATURE: node is the first one in the cluster group, no pull");
}
} else if (policy.equalsIgnoreCase("nodeOnly")) {
LOGGER.debug("CELLAR FEATURE: sync policy set as 'nodeOnly' for cluster group " + group.getName());